package yh;

/**
 * 常量的定义
 */
public class ConstantDemo {
    public static void main(String[] args) {
        //定义整数常量
        final byte b1=1;
        final short b2=2;
        final int b3=3;
        final long b4=4L;
        //定义浮点数常量
        final float b5=5.1F;
        final double b6=6.6;
        //定义字符常量
        final char b7='a';
        //定义布尔常量
        final boolean b8=true;
        System.out.println(b1);
        System.out.println(b2);
        System.out.println(b3);
        System.out.println(b4);
        System.out.println(b5);
        System.out.println(b6);
        System.out.println(b7);
        System.out.println(b8);
    }
}
